<?php

namespace App\Models;

use Dcat\Admin\Models\Administrator;
use Dcat\Admin\Traits\HasDateTimeFormatter;

use Illuminate\Database\Eloquent\Model;

class Paint extends Model
{
    use HasDateTimeFormatter;
    protected $table = 'paint';
    protected $fillable = ['mechanism_id','name','cover','data','book_id', 'unit_id'];

    public function mechanism()
    {
        return $this->belongsTo(Administrator::class, 'mechanism_id');
    }
}
